#include<stdio.h>
#include<stdlib.h>
#include<unistd.h>
#include<sys/stat.h>

int main(int argc, char* argv[])
{
  struct stat buf;

  int ret = stat(argv[1], &buf);
  if (ret == -1)
  {
    perror("stat error");
    exit(1);
  }

  printf("file size:%ld\n", buf.st_size);

  return 0;
}
